home *** CD-ROM | disk | FTP | other *** search
/ Developer CD Series 1999 May: Tool Chest / Developer CD Series Tool Chest (Apple Computer)(May 1999).iso / Tool Chest / Networking / Network Watch (DMZ) v1.5 / sources / SpinCursor.h < prev   
Encoding:
C/C++ Source or Header  |  1996-04-25  |  1.1 KB  |  45 lines  |  [TEXT/MPCC]

  1. /*
  2.     File: SpinCursor.h
  3.     By: Nitin Ganatra.
  4.     Modifications by Rich Kubota
  5. */
  6.  
  7. #ifndef __SPINCURSOR__
  8. #define __SPINCURSOR__
  9.  
  10. #include <Types.h>
  11. #include <Quickdraw.h>
  12. #include <Resources.h>
  13. #include <Events.h>
  14. #include <ToolUtils.h>
  15.  
  16. #if powerc
  17. #pragma options align=mac68k
  18. #endif
  19.  
  20. // defines for the spin cursor
  21. #define kDontSpinCursor        -1L
  22. #define kSpinEvery5Ticks    5
  23. #define kDelay30Ticks        30
  24.  
  25. /* Redefine HiWord() as a macro to increase speed. */
  26. #define HiWrd(aLong)    (((aLong) >> 16) & 0xFFFF)
  27.  
  28. typedef struct                                        /* The structure of an 'acur' resource */
  29. {
  30.     short numberOfFrames;                            /* number of cursors to animate */
  31.     short whichFrame;                                    /* current frame number */
  32.     CursHandle frame[1];                            /* Pointer to the first cursor */
  33. } animatedCursor, *animatedCursorPtr, **animatedCursorHandle;
  34.  
  35. extern Boolean         InitAnimatedCursors(short acurID);
  36. extern void         StartAnimatedCursors(short interval, short deferral);
  37. extern void         StopAnimatedCursors(void);
  38. extern void            ReleaseAnimatedCursors(void);
  39. extern void         SpinTheCursor(void);
  40.  
  41. #if powerc
  42. #pragma options align=reset
  43. #endif
  44.  
  45. #endif     // __SPINCURSOR__